﻿using HuaweiCloud.Dotnet.Samples.Common;
using Microsoft.EntityFrameworkCore;

namespace HuaweiCloud.Dotnet.Samples.ESports.Main.Entities
{
    /// <summary>
    /// 设备绑定关系
    /// UserId作为索引
    /// </summary>
    [Index(nameof(UserId))]
    public class BindInfo : BaseEntity<Guid>
    {
        public Guid? UserId { get; set; }
        public Guid DeviceId { get; set; }
        public BindInfo(Guid id, Guid? userId, Guid deviceId)
        {
            Id = id;
            UserId = userId;
            DeviceId = deviceId;
        }
    }
}
